import request from '@/utils/request'

// 查询检验任务列表
export function listInspectionTask(query) {
  return request({
    url: '/qep/inspection/task/list',
    method: 'get',
    params: query
  })
}

// 查询检验任务详细
export function getInspectionTask(id) {
  return request({
    url: '/qep/inspection/task/' + id,
    method: 'get'
  })
}

// 新增检验任务
export function addInspectionTask(data) {
  return request({
    url: '/qep/inspection/task',
    method: 'post',
    data: data
  })
}

// 修改检验任务
export function updateInspectionTask(data) {
  return request({
    url: '/qep/inspection/task',
    method: 'put',
    data: data
  })
}

// 删除检验任务
export function delInspectionTask(id) {
  return request({
    url: '/qep/inspection/task/' + id,
    method: 'delete'
  })
}

// 导出检验任务
export function exportInspectionTask(query) {
  return request({
    url: '/qep/inspection/task/export',
    method: 'post',
    data: query,
    responseType: 'blob'
  })
} 